.document-container {
  display: flex;
  height: 100vh;
  background-color: #f5f5f5;
}

.sidebar {
  width: 280px;
  background-color: white;
  border-right: 1px solid #e8e8e8;
  display: flex;
  flex-direction: column;
  box-shadow: 2px 0 8px rgb(0 0 0 / 10%);
}

.sidebar-header {
  padding: 20px 16px;
  border-bottom: 1px solid #f0f0f0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  font-size: 24px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1890ff, #52c41a);
  border-radius: 8px;
  color: white;
}

.logo-text {
  flex: 1;
}

.logo-title {
  font-size: 18px;
  font-weight: 600;
  color: #262626;
  line-height: 1.2;
}

.logo-subtitle {
  font-size: 12px;
  color: #8c8c8c;
  margin-top: 2px;
}

.nav-menu {
  flex: 1;
  padding: 16px 0;
  overflow-y: auto;
}

.nav-item {
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 2px 8px;
  border-radius: 6px;
}

.nav-item:hover {
  background-color: #f5f5f5;
}

.nav-item.active {
  background-color: #e6f7ff;
  border-left: 3px solid #1890ff;
}

.nav-item-content {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  gap: 12px;
  position: relative;
}

.nav-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
}

.nav-label {
  flex: 1;
  font-size: 14px;
  color: #262626;
  font-weight: 500;
}

.nav-badge {
  background-color: #f0f0f0;
  color: #8c8c8c;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 10px;
  white-space: nowrap;
}

.expand-icon {
  font-size: 12px;
  color: #8c8c8c;
  transition: transform 0.2s ease;
}

.expand-icon.expanded {
  transform: rotate(90deg);
}

.sub-item {
  margin-left: 8px;
}

.sub-item .nav-item-content {
  padding: 8px 16px;
}

.sub-item .nav-label {
  font-size: 13px;
  color: #595959;
}

.sub-items {
  margin-left: 8px;
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid #f0f0f0;
}

.sidebar-footer .nav-item {
  margin: 0;
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  background-color: #f5f5f5;
}

.content-area {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
}

.content-header {
  margin-bottom: 32px;
}

.content-header h1 {
  font-size: 28px;
  font-weight: 600;
  color: #262626;
  margin: 0 0 8px;
}

.content-header p {
  font-size: 16px;
  color: #8c8c8c;
  margin: 0;
}

.welcome-card {
  background: white;
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 2px 8px rgb(0 0 0 / 10%);
}

.welcome-card h2 {
  font-size: 24px;
  font-weight: 600;
  color: #262626;
  margin: 0 0 16px;
}

.welcome-card > p {
  font-size: 16px;
  color: #595959;
  margin: 0 0 32px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
}

.feature-item {
  padding: 24px;
  background: #fafafa;
  border-radius: 8px;
  border: 1px solid #f0f0f0;
  transition: all 0.2s ease;
}

.feature-item:hover {
  background: #f5f5f5;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgb(0 0 0 / 10%);
}

.feature-item h3 {
  font-size: 18px;
  font-weight: 600;
  color: #262626;
  margin: 0 0 8px;
}

.feature-item p {
  font-size: 14px;
  color: #8c8c8c;
  margin: 0;
}

/* 顶部导航栏样式 */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background-color: white;
  border-bottom: 1px solid #e8e8e8;
  box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.header-left {
  flex: 1;
  max-width: 400px;
}

.search-container {
  position: relative;
}

.search-input {
  display: flex;
  align-items: center;
  background-color: #f5f5f5;
  border-radius: 8px;
  padding: 8px 12px;
  border: 1px solid #e0e0e0;
  transition: all 0.2s ease;
}

.search-input:focus-within {
  background-color: white;
  border-color: #1890ff;
  box-shadow: 0 0 0 2px rgb(24 144 255 / 20%);
}

.search-icon {
  font-size: 16px;
  color: #8c8c8c;
  margin-right: 8px;
}

.search-field {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 14px;
  color: #262626;
  outline: none;
}

.search-field::placeholder {
  color: #8c8c8c;
}

.filter-icon {
  font-size: 12px;
  color: #8c8c8c;
  margin-left: 8px;
  cursor: pointer;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid #d9d9d9;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background-color: #1890ff;
  color: white;
  border-color: #1890ff;
}

.btn-primary:hover {
  background-color: #40a9ff;
  border-color: #40a9ff;
}

.btn-secondary {
  background-color: white;
  color: #262626;
}

.btn-secondary:hover {
  background-color: #f5f5f5;
  border-color: #40a9ff;
}

.btn-icon {
  font-size: 14px;
}

.btn-text {
  white-space: nowrap;
}

.header-icons {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: 16px;
}

.icon-item {
  position: relative;
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.icon-item:hover {
  background-color: #f5f5f5;
}

.icon {
  font-size: 18px;
  color: #262626;
}

.notification-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  background-color: #ff4d4f;
  color: white;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 4px;
  border-radius: 8px;
  min-width: 16px;
  text-align: center;
  line-height: 1;
}

/* 新建文档弹窗样式 */
.create-btn {
  position: relative;
}

.create-modal {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgb(0 0 0 / 20%);
  width: 380px;
  height: auto;
  overflow: hidden;
  z-index: 1000;
  margin-top: 8px;
  animation: modal-slide-in 0.3s ease-out;
}

@keyframes modal-slide-in {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  padding: 12px 16px;
  border-bottom: 1px solid #f0f0f0;
}

.modal-title {
  font-size: 13px;
  color: #8c8c8c;
  font-weight: 500;
}

.modal-content {
  padding: 16px;
}

.create-section {
  margin-bottom: 5px;
}

.create-section:last-child {
  margin-bottom: 0;
}

.section-title {
  font-size: 14px;
  font-weight: 600;
  color: #262626;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.collaboration-icon {
  font-size: 10px;
}

.create-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.office-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.create-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.create-item:hover {
  background-color: #f5f5f5;
  border-color: #e8e8e8;
}

.create-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: white;
  font-weight: 600;
}

.create-icon.ai-table {
  background: linear-gradient(135deg, #722ed1, #b37feb);
}

.create-icon.document {
  background: linear-gradient(135deg, #1890ff, #40a9ff);
}

.create-icon.spreadsheet {
  background: linear-gradient(135deg, #52c41a, #73d13d);
}

.create-icon.slideshow {
  background: linear-gradient(135deg, #fa8c16, #ffa940);
}

.create-icon.mindmap {
  background: linear-gradient(135deg, #722ed1, #b37feb);
}

.create-icon.whiteboard {
  background: linear-gradient(135deg, #fff, #f0f0f0);
  color: #fa8c16;
  border: 1px solid #e8e8e8;
}

.create-icon.form {
  background: linear-gradient(135deg, #13c2c2, #36cfc9);
}

.create-icon.pdf {
  background: linear-gradient(135deg, #fa8c16, #ffa940);
}

.create-icon.voice {
  background: linear-gradient(135deg, #722ed1, #b37feb);
}

.create-icon.link {
  background: linear-gradient(135deg, #13c2c2, #36cfc9);
}

.create-icon.folder {
  background: linear-gradient(135deg, #13c2c2, #36cfc9);
}

.create-icon.word {
  background: linear-gradient(135deg, #1890ff, #40a9ff);
}

.create-icon.excel {
  background: linear-gradient(135deg, #52c41a, #73d13d);
}

.create-icon.powerpoint {
  background: linear-gradient(135deg, #fa8c16, #ffa940);
}

.create-icon.template {
  background: linear-gradient(135deg, #1890ff, #40a9ff);
}

.create-icon.knowledge {
  background: linear-gradient(135deg, #1890ff, #40a9ff);
}

.create-label {
  font-size: 12px;
  color: #262626;
  font-weight: 500;
  text-align: center;
}

.template-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.template-item:hover {
  background-color: #f5f5f5;
  border-color: #e8e8e8;
}

.template-info {
  flex: 1;
}

.template-desc {
  font-size: 11px;
  color: #8c8c8c;
  margin-top: 3px;
  line-height: 1.3;
}

/* 响应式设计 */
@media (width <= 768px) {
  .document-container {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    height: auto;
    max-height: 60vh;
  }

  .content-area {
    padding: 16px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .header {
    flex-direction: column;
    gap: 16px;
    padding: 12px 16px;
  }

  .header-left {
    max-width: 100%;
  }

  .header-right {
    flex-wrap: wrap;
    justify-content: center;
  }

  .btn-text {
    display: none;
  }

  .header-icons {
    margin-left: 0;
  }

  .create-modal {
    width: 95vw;
    max-width: 350px;
    left: 50%;
    transform: translateX(-50%);
  }

  .create-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .office-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .create-icon {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }

  .create-label {
    font-size: 11px;
  }
}
